package user_interaction;

import java.io.IOException;

import javax.swing.JFrame;


import dca.DiseaseRegistry;
import dca.PatientRegistry;
import dca.SymptomRegistry;

/**
 * Main interface/Tester. Opens three windows for testing different parts of the system.
 * I unfortunately ran out of time for implementing communication between JFrames,
 * so it is necessary to close and rerun the program for additions to be included across the different parts.
 * @author Johan Sivertsen
 *
 */
public class GUI_tester {
	
	public static void main(String[] args) throws IOException{
		
		
		SymptomRegistry theSymptomBase = new SymptomRegistry("symptomlist090112");
		DiseaseRegistry theDiseaseBase = new DiseaseRegistry("diseaselist090112");
		PatientRegistry thePatientBase = new PatientRegistry("patientlist090112");

		JFrame frameSymp = new Symptom_GUI(theSymptomBase);
		frameSymp.setTitle("Symptom Manager");
		frameSymp.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		frameSymp.setVisible(true);		
				
		JFrame frameDisease = new Disease_GUI(theDiseaseBase,theSymptomBase);
		frameDisease.setTitle("Disease Manager");
		frameDisease.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		frameDisease.setVisible(true);
		
		JFrame framePatient = new Patient_GUI(thePatientBase,theSymptomBase,theDiseaseBase);
		framePatient.setTitle("Patient Manager");
		framePatient.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		framePatient.setVisible(true);

	
		
}

}
